<template>
	<view class="bidding-item" v-if="itemData.type!='中标' ">
		<view class="item-title">
			<image :src="getBiddingType(itemData.type,itemData.bidding_type)" mode=""></image>
			<text> {{itemData.bidding_name}}</text>
		</view>
		<view class="item-company">
			{{itemData.company_id_name}}
		</view>
		<view class="item-date">
			{{itemData.create_date}}
		</view>
	</view>
</template>

<script>
	export default {
		props: {
			itemData: {
				type: Object
			}
		},
		mounted() {

		},
		data() {
			return {

			}
		},
		methods: {
			getBiddingType(type, bidding_type) {
				if (type == '变更公告') {
					// return require('@/static/image/bidding/status4.png')
					return require('../../../../pagesB/static/assets/image/bidding/status4.png')
				} else if (type == '中标') {
					return require('../../../../pagesB/static/assets/image/bidding/status3.png')
				} else {
					if (bidding_type == '公开招标') {
						return require('../../../../pagesB/static/assets/image/bidding/status1.png')
					} else if (bidding_type == '单一来源') {
						return require('../../../../pagesB/static/assets/image/bidding/status2.png')
					} else if (bidding_type == '邀请招标') {
						return require('../../../../pagesB/static/assets/image/bidding/status5.png')
					}
				}
			}
		}
	}
</script>

<style lang="less" scoped>
	.bidding-item {
		background: #FFFFFF;
		padding: 36rpx 30rpx;
		position: relative;
	}

	.item-title {
		image {
			width: 120rpx;
			height: 38rpx;
			margin-bottom: -5rpx;
			margin-right: 20rpx;
		}

		text {
			font-size: 32rpx;
			font-weight: 500;
			color: #333333;
		}
	}

	.item-label {
		display: flex;
		align-items: center;
		margin-top: 18rpx;
		flex-wrap: wrap;

		.item-label-item {
			padding: 0 16rpx;
			height: 40rpx;
			line-height: 40rpx;
			background: #F4F5F9;
			border-radius: 6rpx;
			font-size: 24rpx;
			font-weight: 400;
			color: #666666;
			margin-right: 20rpx;
			margin-top: 10rpx;
		}
	}

	.item-company {
		font-size: 26rpx;
		font-weight: 400;
		margin-top: 34rpx;
		color: #666666;
		max-width: 312rpx;
		overflow: hidden;
		text-overflow: ellipsis;
		white-space: nowrap;
	}

	.item-date {
		position: absolute;
		right: 30rpx;
		bottom: 36rpx;

		font-size: 24rpx;
		font-weight: 400;
		color: #999999;
	}
</style>
